import http from '@/http'

export function getStar (id) {
  return http.get(`rest/Invi/star/${id}`)
}

export function getSend (id) {
  return http.get(`rest/Invi/send/${id}`)
}

export function getLike (id) {
  return http.get(`rest/Invi/like/${id}`)
}

export function resetPwd (OldPwd, NewPwd, _id) {
  const data = { OldPwd, NewPwd, _id }
  return http.post('resetpwd', data)
}

export function getData (id) {
  return http.get(`rest/User/${id}`)
}

export function modifyData (_id, icon, nickname, email) {
  const data = { _id, icon, nickname, email }
  return http.put('rest/User', data)
}
